//
// Created by jinling on 2025/6/25.
//

#pragma once
#include "NonCopyable.h"
#include "FileLog.h"
#include<string>
#include<iostream>

#include "FileLogMgr.h"

namespace tmms
{
    namespace base
    {
        enum LogLevel //日志类别
        {
            KTrace,
            KDebug,
            KInfo,
            KWarn,
            KMaxNumOfLogLevel,
        };

        class Logger:public base::NonCopyable
        {
        public:
            Logger(const FileLogPter &log);
            ~Logger() =default;
            void SetLogLevel(const LogLevel& level);
            LogLevel GetLogLevel() const ;
            void Write(const std::string &msg);
        private:
            LogLevel level_{KDebug};
            FileLogPter log_;
        };
    }
}
